<script setup>
  import { storeToRefs } from 'pinia';
  import { useSeverLoadingStore } from '@/stores/severLoading';
  import { useThemeStore } from '@/stores/theme'
  const themeStore = useThemeStore()
  const myLoading = useSeverLoadingStore();
  const { loading } = storeToRefs(myLoading); //解构赋值，数据双向绑定，关联store
  // const antTheme = reactive({
  //   token: {
  //     colorPrimary: '#722ED1',
  //     colorBgContainer: '#fff'
  //   }
  // });

</script>

<template>
  <a-config-provider :theme="themeStore.themeConfig">
    <a-spin :spinning="loading" class="fullLoading" tip="Loading...">
      <router-view />
    </a-spin>
  </a-config-provider>
</template>
<style scoped>
  .fullLoading {
    height: 100vh;
  }
</style>
